package com.zretc.service.impl;

import java.util.List;
import java.util.Map;

import com.zretc.dao.CollectDao;
import com.zretc.dao.impl.CollectDaoImpl;
import com.zretc.entity.Collect;
import com.zretc.service.CollectService;
import com.zretc.util.PageInfo;

public class CollectServiceImpl implements CollectService {
	private CollectDao collectDao = new CollectDaoImpl();

	@Override
	public int addCollect(Map<String, Object> map) {
		return collectDao.insertCollect(map);
	}

	@Override
	public int unCollect(Map<String, Object> map) {
		return collectDao.delectCollect(map);
	}

	@Override
	public Collect getCollect(Integer songId, Integer accountId) {
		
		return collectDao.selectCollectBySongId(songId, accountId);
	}

	@Override
	public PageInfo<Collect> getCollectByAccountId(Map<String, String> map) {
		
		return collectDao.selectCollectByAccountId(map);
	}
}
